package com.erp.business.login
{
	import com.adobe.cairngorm.business.ServiceLocator;

	import mx.rpc.IResponder;

	import com.erp.vo.ErpbaseUser;

	public class LoginDelegate
	{
		public var responder:IResponder;
		public var service:Object;

		public function LoginDelegate(responder:IResponder)
		{
			this.service=ServiceLocator.getInstance().getRemoteObject("loginService");
			this.responder=responder;
		}

		public function login(user:ErpbaseUser):void
		{
			var call:Object=service.login(user);
			call.addResponder(responder);
		}

		public function isLogin():void
		{
			var call:Object=service.isLogin();
			call.addResponder(responder);
		}
	}
}